using UnityEngine;

namespace Voodoo.Meta
{
	[RequireComponent(typeof(Leaderboard))]
	public class LeaderboardAudio : MonoBehaviour
	{
		[SerializeField]
		private AudioSource _audioSource;

		public void Play(AudioClip clip)
		{
			_audioSource.clip = clip;
			_audioSource.Play();
		}

		public void PlayOneShot(AudioClip clip)
		{
			_audioSource.PlayOneShot(clip);
		}

		public void Stop()
		{
			_audioSource.Stop();
		}
	}
}
